3.3.19 \(\int \frac {1}{(a+b \sec ^2(c+d x))^4} \, dx\) [219]

3.3.19.1 Optimal result
3.3.19.2 Mathematica [C] (warning: unable to verify)
3.3.19.3 Rubi [A] (verified)
3.3.19.4 Maple [A] (verified)
3.3.19.5 Fricas [B] (verification not implemented)
3.3.19.6 Sympy [F(-1)]
3.3.19.7 Maxima [B] (verification not implemented)
3.3.19.8 Giac [A] (verification not implemented)
3.3.19.9 Mupad [B] (verification not implemented)

3.3.19.1 Optimal result

Integrand size = 14, antiderivative size = 204 \[ \int \frac {1}{\left (a+b \sec ^2(c+d x)\right )^4} \, dx=\frac {x}{a^4}-\frac {\sqrt {b} \left (35 a^3+70 a^2 b+56 a b^2+16 b^3\right ) \arctan \left (\frac {\sqrt {b} \tan (c+d x)}{\sqrt {a+b}}\right )}{16 a^4 (a+b)^{7/2} d}-\frac {b \tan (c+d x)}{6 a (a+b) d \left (a+b+b \tan ^2(c+d x)\right )^3}-\frac {b (11 a+6 b) \tan (c+d x)}{24 a^2 (a+b)^2 d \left (a+b+b \tan ^2(c+d x)\right )^2}-\frac {b \left (19 a^2+22 a b+8 b^2\right ) \tan (c+d x)}{16 a^3 (a+b)^3 d \left (a+b+b \tan ^2(c+d x)\right )} \]

output
x/a^4-1/16*(35*a^3+70*a^2*b+56*a*b^2+16*b^3)*arctan(b^(1/2)*tan(d*x+c)/(a+ 
b)^(1/2))*b^(1/2)/a^4/(a+b)^(7/2)/d-1/6*b*tan(d*x+c)/a/(a+b)/d/(a+b+b*tan( 
d*x+c)^2)^3-1/24*b*(11*a+6*b)*tan(d*x+c)/a^2/(a+b)^2/d/(a+b+b*tan(d*x+c)^2 
)^2-1/16*b*(19*a^2+22*a*b+8*b^2)*tan(d*x+c)/a^3/(a+b)^3/d/(a+b+b*tan(d*x+c 
)^2)
 
3.3.19.2 Mathematica [C] (warning: unable to verify)

Result contains complex when optimal does not.

Time = 9.44 (sec) , antiderivative size = 1411, normalized size of antiderivative = 6.92 \[ \int \frac {1}{\left (a+b \sec ^2(c+d x)\right )^4} \, dx=\frac {\left (35 a^3+70 a^2 b+56 a b^2+16 b^3\right ) (a+2 b+a \cos (2 c+2 d x))^4 \sec ^8(c+d x) \left (\frac {b \arctan \left (\sec (d x) \left (\frac {\cos (2 c)}{2 \sqrt {a+b} \sqrt {b \cos (4 c)-i b \sin (4 c)}}-\frac {i \sin (2 c)}{2 \sqrt {a+b} \sqrt {b \cos (4 c)-i b \sin (4 c)}}\right ) (-a \sin (d x)-2 b \sin (d x)+a \sin (2 c+d x))\right ) \cos (2 c)}{256 a^4 \sqrt {a+b} d \sqrt {b \cos (4 c)-i b \sin (4 c)}}-\frac {i b \arctan \left (\sec (d x) \left (\frac {\cos (2 c)}{2 \sqrt {a+b} \sqrt {b \cos (4 c)-i b \sin (4 c)}}-\frac {i \sin (2 c)}{2 \sqrt {a+b} \sqrt {b \cos (4 c)-i b \sin (4 c)}}\right ) (-a \sin (d x)-2 b \sin (d x)+a \sin (2 c+d x))\right ) \sin (2 c)}{256 a^4 \sqrt {a+b} d \sqrt {b \cos (4 c)-i b \sin (4 c)}}\right )}{(a+b)^3 \left (a+b \sec ^2(c+d x)\right )^4}+\frac {(a+2 b+a \cos (2 c+2 d x)) \sec (2 c) \sec ^8(c+d x) \left (480 a^6 d x \cos (2 c)+3168 a^5 b d x \cos (2 c)+8928 a^4 b^2 d x \cos (2 c)+14112 a^3 b^3 d x \cos (2 c)+13248 a^2 b^4 d x \cos (2 c)+6912 a b^5 d x \cos (2 c)+1536 b^6 d x \cos (2 c)+360 a^6 d x \cos (2 d x)+2232 a^5 b d x \cos (2 d x)+5688 a^4 b^2 d x \cos (2 d x)+7272 a^3 b^3 d x \cos (2 d x)+4608 a^2 b^4 d x \cos (2 d x)+1152 a b^5 d x \cos (2 d x)+360 a^6 d x \cos (4 c+2 d x)+2232 a^5 b d x \cos (4 c+2 d x)+5688 a^4 b^2 d x \cos (4 c+2 d x)+7272 a^3 b^3 d x \cos (4 c+2 d x)+4608 a^2 b^4 d x \cos (4 c+2 d x)+1152 a b^5 d x \cos (4 c+2 d x)+144 a^6 d x \cos (2 c+4 d x)+720 a^5 b d x \cos (2 c+4 d x)+1296 a^4 b^2 d x \cos (2 c+4 d x)+1008 a^3 b^3 d x \cos (2 c+4 d x)+288 a^2 b^4 d x \cos (2 c+4 d x)+144 a^6 d x \cos (6 c+4 d x)+720 a^5 b d x \cos (6 c+4 d x)+1296 a^4 b^2 d x \cos (6 c+4 d x)+1008 a^3 b^3 d x \cos (6 c+4 d x)+288 a^2 b^4 d x \cos (6 c+4 d x)+24 a^6 d x \cos (4 c+6 d x)+72 a^5 b d x \cos (4 c+6 d x)+72 a^4 b^2 d x \cos (4 c+6 d x)+24 a^3 b^3 d x \cos (4 c+6 d x)+24 a^6 d x \cos (8 c+6 d x)+72 a^5 b d x \cos (8 c+6 d x)+72 a^4 b^2 d x \cos (8 c+6 d x)+24 a^3 b^3 d x \cos (8 c+6 d x)+870 a^5 b \sin (2 c)+4292 a^4 b^2 \sin (2 c)+8792 a^3 b^3 \sin (2 c)+9936 a^2 b^4 \sin (2 c)+5824 a b^5 \sin (2 c)+1408 b^6 \sin (2 c)-870 a^5 b \sin (2 d x)-3792 a^4 b^2 \sin (2 d x)-6432 a^3 b^3 \sin (2 d x)-4608 a^2 b^4 \sin (2 d x)-1248 a b^5 \sin (2 d x)+435 a^5 b \sin (4 c+2 d x)+2124 a^4 b^2 \sin (4 c+2 d x)+3972 a^3 b^3 \sin (4 c+2 d x)+3072 a^2 b^4 \sin (4 c+2 d x)+864 a b^5 \sin (4 c+2 d x)-435 a^5 b \sin (2 c+4 d x)-1374 a^4 b^2 \sin (2 c+4 d x)-1248 a^3 b^3 \sin (2 c+4 d x)-384 a^2 b^4 \sin (2 c+4 d x)+87 a^5 b \sin (6 c+4 d x)+366 a^4 b^2 \sin (6 c+4 d x)+408 a^3 b^3 \sin (6 c+4 d x)+144 a^2 b^4 \sin (6 c+4 d x)-87 a^5 b \sin (4 c+6 d x)-116 a^4 b^2 \sin (4 c+6 d x)-44 a^3 b^3 \sin (4 c+6 d x)\right )}{3072 a^4 (a+b)^3 d \left (a+b \sec ^2(c+d x)\right )^4} \]

input
Integrate[(a + b*Sec[c + d*x]^2)^(-4),x]
 
output
((35*a^3 + 70*a^2*b + 56*a*b^2 + 16*b^3)*(a + 2*b + a*Cos[2*c + 2*d*x])^4* 
Sec[c + d*x]^8*((b*ArcTan[Sec[d*x]*(Cos[2*c]/(2*Sqrt[a + b]*Sqrt[b*Cos[4*c 
] - I*b*Sin[4*c]]) - ((I/2)*Sin[2*c])/(Sqrt[a + b]*Sqrt[b*Cos[4*c] - I*b*S 
in[4*c]]))*(-(a*Sin[d*x]) - 2*b*Sin[d*x] + a*Sin[2*c + d*x])]*Cos[2*c])/(2 
56*a^4*Sqrt[a + b]*d*Sqrt[b*Cos[4*c] - I*b*Sin[4*c]]) - ((I/256)*b*ArcTan[ 
Sec[d*x]*(Cos[2*c]/(2*Sqrt[a + b]*Sqrt[b*Cos[4*c] - I*b*Sin[4*c]]) - ((I/2 
)*Sin[2*c])/(Sqrt[a + b]*Sqrt[b*Cos[4*c] - I*b*Sin[4*c]]))*(-(a*Sin[d*x]) 
- 2*b*Sin[d*x] + a*Sin[2*c + d*x])]*Sin[2*c])/(a^4*Sqrt[a + b]*d*Sqrt[b*Co 
s[4*c] - I*b*Sin[4*c]])))/((a + b)^3*(a + b*Sec[c + d*x]^2)^4) + ((a + 2*b 
 + a*Cos[2*c + 2*d*x])*Sec[2*c]*Sec[c + d*x]^8*(480*a^6*d*x*Cos[2*c] + 316 
8*a^5*b*d*x*Cos[2*c] + 8928*a^4*b^2*d*x*Cos[2*c] + 14112*a^3*b^3*d*x*Cos[2 
*c] + 13248*a^2*b^4*d*x*Cos[2*c] + 6912*a*b^5*d*x*Cos[2*c] + 1536*b^6*d*x* 
Cos[2*c] + 360*a^6*d*x*Cos[2*d*x] + 2232*a^5*b*d*x*Cos[2*d*x] + 5688*a^4*b 
^2*d*x*Cos[2*d*x] + 7272*a^3*b^3*d*x*Cos[2*d*x] + 4608*a^2*b^4*d*x*Cos[2*d 
*x] + 1152*a*b^5*d*x*Cos[2*d*x] + 360*a^6*d*x*Cos[4*c + 2*d*x] + 2232*a^5* 
b*d*x*Cos[4*c + 2*d*x] + 5688*a^4*b^2*d*x*Cos[4*c + 2*d*x] + 7272*a^3*b^3* 
d*x*Cos[4*c + 2*d*x] + 4608*a^2*b^4*d*x*Cos[4*c + 2*d*x] + 1152*a*b^5*d*x* 
Cos[4*c + 2*d*x] + 144*a^6*d*x*Cos[2*c + 4*d*x] + 720*a^5*b*d*x*Cos[2*c + 
4*d*x] + 1296*a^4*b^2*d*x*Cos[2*c + 4*d*x] + 1008*a^3*b^3*d*x*Cos[2*c + 4* 
d*x] + 288*a^2*b^4*d*x*Cos[2*c + 4*d*x] + 144*a^6*d*x*Cos[6*c + 4*d*x] ...
 
3.3.19.3 Rubi [A] (verified)

Time = 0.41 (sec) , antiderivative size = 245, normalized size of antiderivative = 1.20, number of steps used = 10, number of rules used = 9, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.643, Rules used = {3042, 4616, 316, 402, 27, 402, 397, 216, 218}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int \frac {1}{\left (a+b \sec ^2(c+d x)\right )^4} \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {1}{\left (a+b \sec (c+d x)^2\right )^4}dx\)

\(\Big \downarrow \) 4616

\(\displaystyle \frac {\int \frac {1}{\left (\tan ^2(c+d x)+1\right ) \left (b \tan ^2(c+d x)+a+b\right )^4}d\tan (c+d x)}{d}\)

\(\Big \downarrow \) 316

\(\displaystyle \frac {\frac {\int \frac {-5 b \tan ^2(c+d x)+6 a+b}{\left (\tan ^2(c+d x)+1\right ) \left (b \tan ^2(c+d x)+a+b\right )^3}d\tan (c+d x)}{6 a (a+b)}-\frac {b \tan (c+d x)}{6 a (a+b) \left (a+b \tan ^2(c+d x)+b\right )^3}}{d}\)

\(\Big \downarrow \) 402

\(\displaystyle \frac {\frac {\frac {\int \frac {3 \left (8 a^2+5 b a+2 b^2-b (11 a+6 b) \tan ^2(c+d x)\right )}{\left (\tan ^2(c+d x)+1\right ) \left (b \tan ^2(c+d x)+a+b\right )^2}d\tan (c+d x)}{4 a (a+b)}-\frac {b (11 a+6 b) \tan (c+d x)}{4 a (a+b) \left (a+b \tan ^2(c+d x)+b\right )^2}}{6 a (a+b)}-\frac {b \tan (c+d x)}{6 a (a+b) \left (a+b \tan ^2(c+d x)+b\right )^3}}{d}\)

\(\Big \downarrow \) 27

\(\displaystyle \frac {\frac {\frac {3 \int \frac {8 a^2+5 b a+2 b^2-b (11 a+6 b) \tan ^2(c+d x)}{\left (\tan ^2(c+d x)+1\right ) \left (b \tan ^2(c+d x)+a+b\right )^2}d\tan (c+d x)}{4 a (a+b)}-\frac {b (11 a+6 b) \tan (c+d x)}{4 a (a+b) \left (a+b \tan ^2(c+d x)+b\right )^2}}{6 a (a+b)}-\frac {b \tan (c+d x)}{6 a (a+b) \left (a+b \tan ^2(c+d x)+b\right )^3}}{d}\)

\(\Big \downarrow \) 402

\(\displaystyle \frac {\frac {\frac {3 \left (\frac {\int \frac {16 a^3+29 b a^2+26 b^2 a+8 b^3-b \left (19 a^2+22 b a+8 b^2\right ) \tan ^2(c+d x)}{\left (\tan ^2(c+d x)+1\right ) \left (b \tan ^2(c+d x)+a+b\right )}d\tan (c+d x)}{2 a (a+b)}-\frac {b \left (19 a^2+22 a b+8 b^2\right ) \tan (c+d x)}{2 a (a+b) \left (a+b \tan ^2(c+d x)+b\right )}\right )}{4 a (a+b)}-\frac {b (11 a+6 b) \tan (c+d x)}{4 a (a+b) \left (a+b \tan ^2(c+d x)+b\right )^2}}{6 a (a+b)}-\frac {b \tan (c+d x)}{6 a (a+b) \left (a+b \tan ^2(c+d x)+b\right )^3}}{d}\)

\(\Big \downarrow \) 397

\(\displaystyle \frac {\frac {\frac {3 \left (\frac {\frac {16 (a+b)^3 \int \frac {1}{\tan ^2(c+d x)+1}d\tan (c+d x)}{a}-\frac {b \left (35 a^3+70 a^2 b+56 a b^2+16 b^3\right ) \int \frac {1}{b \tan ^2(c+d x)+a+b}d\tan (c+d x)}{a}}{2 a (a+b)}-\frac {b \left (19 a^2+22 a b+8 b^2\right ) \tan (c+d x)}{2 a (a+b) \left (a+b \tan ^2(c+d x)+b\right )}\right )}{4 a (a+b)}-\frac {b (11 a+6 b) \tan (c+d x)}{4 a (a+b) \left (a+b \tan ^2(c+d x)+b\right )^2}}{6 a (a+b)}-\frac {b \tan (c+d x)}{6 a (a+b) \left (a+b \tan ^2(c+d x)+b\right )^3}}{d}\)

\(\Big \downarrow \) 216

\(\displaystyle \frac {\frac {\frac {3 \left (\frac {\frac {16 (a+b)^3 \arctan (\tan (c+d x))}{a}-\frac {b \left (35 a^3+70 a^2 b+56 a b^2+16 b^3\right ) \int \frac {1}{b \tan ^2(c+d x)+a+b}d\tan (c+d x)}{a}}{2 a (a+b)}-\frac {b \left (19 a^2+22 a b+8 b^2\right ) \tan (c+d x)}{2 a (a+b) \left (a+b \tan ^2(c+d x)+b\right )}\right )}{4 a (a+b)}-\frac {b (11 a+6 b) \tan (c+d x)}{4 a (a+b) \left (a+b \tan ^2(c+d x)+b\right )^2}}{6 a (a+b)}-\frac {b \tan (c+d x)}{6 a (a+b) \left (a+b \tan ^2(c+d x)+b\right )^3}}{d}\)

\(\Big \downarrow \) 218

\(\displaystyle \frac {\frac {\frac {3 \left (\frac {\frac {16 (a+b)^3 \arctan (\tan (c+d x))}{a}-\frac {\sqrt {b} \left (35 a^3+70 a^2 b+56 a b^2+16 b^3\right ) \arctan \left (\frac {\sqrt {b} \tan (c+d x)}{\sqrt {a+b}}\right )}{a \sqrt {a+b}}}{2 a (a+b)}-\frac {b \left (19 a^2+22 a b+8 b^2\right ) \tan (c+d x)}{2 a (a+b) \left (a+b \tan ^2(c+d x)+b\right )}\right )}{4 a (a+b)}-\frac {b (11 a+6 b) \tan (c+d x)}{4 a (a+b) \left (a+b \tan ^2(c+d x)+b\right )^2}}{6 a (a+b)}-\frac {b \tan (c+d x)}{6 a (a+b) \left (a+b \tan ^2(c+d x)+b\right )^3}}{d}\)

input
Int[(a + b*Sec[c + d*x]^2)^(-4),x]
 
output
(-1/6*(b*Tan[c + d*x])/(a*(a + b)*(a + b + b*Tan[c + d*x]^2)^3) + (-1/4*(b 
*(11*a + 6*b)*Tan[c + d*x])/(a*(a + b)*(a + b + b*Tan[c + d*x]^2)^2) + (3* 
(((16*(a + b)^3*ArcTan[Tan[c + d*x]])/a - (Sqrt[b]*(35*a^3 + 70*a^2*b + 56 
*a*b^2 + 16*b^3)*ArcTan[(Sqrt[b]*Tan[c + d*x])/Sqrt[a + b]])/(a*Sqrt[a + b 
]))/(2*a*(a + b)) - (b*(19*a^2 + 22*a*b + 8*b^2)*Tan[c + d*x])/(2*a*(a + b 
)*(a + b + b*Tan[c + d*x]^2))))/(4*a*(a + b)))/(6*a*(a + b)))/d
 

3.3.19.3.1 Defintions of rubi rules used

rule 27
Int[(a_)*(Fx_), x_Symbol] :> Simp[a   Int[Fx, x], x] /; FreeQ[a, x] &&  !Ma 
tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
 

rule 216
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[b, 2]))*A 
rcTan[Rt[b, 2]*(x/Rt[a, 2])], x] /; FreeQ[{a, b}, x] && PosQ[a/b] && (GtQ[a 
, 0] || GtQ[b, 0])
 

rule 218
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[a/b, 2]/a)*ArcTan[x/R 
t[a/b, 2]], x] /; FreeQ[{a, b}, x] && PosQ[a/b]
 

rule 316
Int[((a_) + (b_.)*(x_)^2)^(p_)*((c_) + (d_.)*(x_)^2)^(q_), x_Symbol] :> Sim 
p[(-b)*x*(a + b*x^2)^(p + 1)*((c + d*x^2)^(q + 1)/(2*a*(p + 1)*(b*c - a*d)) 
), x] + Simp[1/(2*a*(p + 1)*(b*c - a*d))   Int[(a + b*x^2)^(p + 1)*(c + d*x 
^2)^q*Simp[b*c + 2*(p + 1)*(b*c - a*d) + d*b*(2*(p + q + 2) + 1)*x^2, x], x 
], x] /; FreeQ[{a, b, c, d, q}, x] && NeQ[b*c - a*d, 0] && LtQ[p, -1] &&  ! 
( !IntegerQ[p] && IntegerQ[q] && LtQ[q, -1]) && IntBinomialQ[a, b, c, d, 2, 
 p, q, x]
 

rule 397
Int[((e_) + (f_.)*(x_)^2)/(((a_) + (b_.)*(x_)^2)*((c_) + (d_.)*(x_)^2)), x_ 
Symbol] :> Simp[(b*e - a*f)/(b*c - a*d)   Int[1/(a + b*x^2), x], x] - Simp[ 
(d*e - c*f)/(b*c - a*d)   Int[1/(c + d*x^2), x], x] /; FreeQ[{a, b, c, d, e 
, f}, x]
 

rule 402
Int[((a_) + (b_.)*(x_)^2)^(p_)*((c_) + (d_.)*(x_)^2)^(q_.)*((e_) + (f_.)*(x 
_)^2), x_Symbol] :> Simp[(-(b*e - a*f))*x*(a + b*x^2)^(p + 1)*((c + d*x^2)^ 
(q + 1)/(a*2*(b*c - a*d)*(p + 1))), x] + Simp[1/(a*2*(b*c - a*d)*(p + 1)) 
 Int[(a + b*x^2)^(p + 1)*(c + d*x^2)^q*Simp[c*(b*e - a*f) + e*2*(b*c - a*d) 
*(p + 1) + d*(b*e - a*f)*(2*(p + q + 2) + 1)*x^2, x], x], x] /; FreeQ[{a, b 
, c, d, e, f, q}, x] && LtQ[p, -1]
 

rule 3042
Int[u_, x_Symbol] :> Int[DeactivateTrig[u, x], x] /; FunctionOfTrigOfLinear 
Q[u, x]
 

rule 4616
Int[((a_) + (b_.)*sec[(e_.) + (f_.)*(x_)]^2)^(p_), x_Symbol] :> With[{ff = 
FreeFactors[Tan[e + f*x], x]}, Simp[ff/f   Subst[Int[(a + b + b*ff^2*x^2)^p 
/(1 + ff^2*x^2), x], x, Tan[e + f*x]/ff], x]] /; FreeQ[{a, b, e, f, p}, x] 
&& NeQ[a + b, 0] && NeQ[p, -1]
 
3.3.19.4 Maple [A] (verified)

Time = 3.25 (sec) , antiderivative size = 229, normalized size of antiderivative = 1.12

method result size
derivativedivides \(\frac {\frac {\arctan \left (\tan \left (d x +c \right )\right )}{a^{4}}-\frac {b \left (\frac {\frac {b^{2} a \left (19 a^{2}+22 a b +8 b^{2}\right ) \tan \left (d x +c \right )^{5}}{16 a^{3}+48 a^{2} b +48 a \,b^{2}+16 b^{3}}+\frac {\left (17 a^{2}+18 a b +6 b^{2}\right ) a b \tan \left (d x +c \right )^{3}}{6 a^{2}+12 a b +6 b^{2}}+\frac {\left (29 a^{2}+26 a b +8 b^{2}\right ) a \tan \left (d x +c \right )}{16 a +16 b}}{\left (a +b +b \tan \left (d x +c \right )^{2}\right )^{3}}+\frac {\left (35 a^{3}+70 a^{2} b +56 a \,b^{2}+16 b^{3}\right ) \arctan \left (\frac {b \tan \left (d x +c \right )}{\sqrt {\left (a +b \right ) b}}\right )}{16 \left (a^{3}+3 a^{2} b +3 a \,b^{2}+b^{3}\right ) \sqrt {\left (a +b \right ) b}}\right )}{a^{4}}}{d}\) \(229\)
default \(\frac {\frac {\arctan \left (\tan \left (d x +c \right )\right )}{a^{4}}-\frac {b \left (\frac {\frac {b^{2} a \left (19 a^{2}+22 a b +8 b^{2}\right ) \tan \left (d x +c \right )^{5}}{16 a^{3}+48 a^{2} b +48 a \,b^{2}+16 b^{3}}+\frac {\left (17 a^{2}+18 a b +6 b^{2}\right ) a b \tan \left (d x +c \right )^{3}}{6 a^{2}+12 a b +6 b^{2}}+\frac {\left (29 a^{2}+26 a b +8 b^{2}\right ) a \tan \left (d x +c \right )}{16 a +16 b}}{\left (a +b +b \tan \left (d x +c \right )^{2}\right )^{3}}+\frac {\left (35 a^{3}+70 a^{2} b +56 a \,b^{2}+16 b^{3}\right ) \arctan \left (\frac {b \tan \left (d x +c \right )}{\sqrt {\left (a +b \right ) b}}\right )}{16 \left (a^{3}+3 a^{2} b +3 a \,b^{2}+b^{3}\right ) \sqrt {\left (a +b \right ) b}}\right )}{a^{4}}}{d}\) \(229\)
risch \(\text {Expression too large to display}\) \(897\)

input
int(1/(a+b*sec(d*x+c)^2)^4,x,method=_RETURNVERBOSE)
 
output
1/d*(1/a^4*arctan(tan(d*x+c))-b/a^4*((1/16*b^2*a*(19*a^2+22*a*b+8*b^2)/(a^ 
3+3*a^2*b+3*a*b^2+b^3)*tan(d*x+c)^5+1/6*(17*a^2+18*a*b+6*b^2)*a*b/(a^2+2*a 
*b+b^2)*tan(d*x+c)^3+1/16*(29*a^2+26*a*b+8*b^2)*a/(a+b)*tan(d*x+c))/(a+b+b 
*tan(d*x+c)^2)^3+1/16*(35*a^3+70*a^2*b+56*a*b^2+16*b^3)/(a^3+3*a^2*b+3*a*b 
^2+b^3)/((a+b)*b)^(1/2)*arctan(b*tan(d*x+c)/((a+b)*b)^(1/2))))
 
3.3.19.5 Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 618 vs. \(2 (188) = 376\).

Time = 0.36 (sec) , antiderivative size = 1323, normalized size of antiderivative = 6.49 \[ \int \frac {1}{\left (a+b \sec ^2(c+d x)\right )^4} \, dx=\text {Too large to display} \]

input
integrate(1/(a+b*sec(d*x+c)^2)^4,x, algorithm="fricas")
 
output
[1/192*(192*(a^6 + 3*a^5*b + 3*a^4*b^2 + a^3*b^3)*d*x*cos(d*x + c)^6 + 576 
*(a^5*b + 3*a^4*b^2 + 3*a^3*b^3 + a^2*b^4)*d*x*cos(d*x + c)^4 + 576*(a^4*b 
^2 + 3*a^3*b^3 + 3*a^2*b^4 + a*b^5)*d*x*cos(d*x + c)^2 + 192*(a^3*b^3 + 3* 
a^2*b^4 + 3*a*b^5 + b^6)*d*x + 3*((35*a^6 + 70*a^5*b + 56*a^4*b^2 + 16*a^3 
*b^3)*cos(d*x + c)^6 + 35*a^3*b^3 + 70*a^2*b^4 + 56*a*b^5 + 16*b^6 + 3*(35 
*a^5*b + 70*a^4*b^2 + 56*a^3*b^3 + 16*a^2*b^4)*cos(d*x + c)^4 + 3*(35*a^4* 
b^2 + 70*a^3*b^3 + 56*a^2*b^4 + 16*a*b^5)*cos(d*x + c)^2)*sqrt(-b/(a + b)) 
*log(((a^2 + 8*a*b + 8*b^2)*cos(d*x + c)^4 - 2*(3*a*b + 4*b^2)*cos(d*x + c 
)^2 + 4*((a^2 + 3*a*b + 2*b^2)*cos(d*x + c)^3 - (a*b + b^2)*cos(d*x + c))* 
sqrt(-b/(a + b))*sin(d*x + c) + b^2)/(a^2*cos(d*x + c)^4 + 2*a*b*cos(d*x + 
 c)^2 + b^2)) - 4*((87*a^5*b + 116*a^4*b^2 + 44*a^3*b^3)*cos(d*x + c)^5 + 
2*(68*a^4*b^2 + 83*a^3*b^3 + 30*a^2*b^4)*cos(d*x + c)^3 + 3*(19*a^3*b^3 + 
22*a^2*b^4 + 8*a*b^5)*cos(d*x + c))*sin(d*x + c))/((a^10 + 3*a^9*b + 3*a^8 
*b^2 + a^7*b^3)*d*cos(d*x + c)^6 + 3*(a^9*b + 3*a^8*b^2 + 3*a^7*b^3 + a^6* 
b^4)*d*cos(d*x + c)^4 + 3*(a^8*b^2 + 3*a^7*b^3 + 3*a^6*b^4 + a^5*b^5)*d*co 
s(d*x + c)^2 + (a^7*b^3 + 3*a^6*b^4 + 3*a^5*b^5 + a^4*b^6)*d), 1/96*(96*(a 
^6 + 3*a^5*b + 3*a^4*b^2 + a^3*b^3)*d*x*cos(d*x + c)^6 + 288*(a^5*b + 3*a^ 
4*b^2 + 3*a^3*b^3 + a^2*b^4)*d*x*cos(d*x + c)^4 + 288*(a^4*b^2 + 3*a^3*b^3 
 + 3*a^2*b^4 + a*b^5)*d*x*cos(d*x + c)^2 + 96*(a^3*b^3 + 3*a^2*b^4 + 3*a*b 
^5 + b^6)*d*x + 3*((35*a^6 + 70*a^5*b + 56*a^4*b^2 + 16*a^3*b^3)*cos(d*...
 
3.3.19.6 Sympy [F(-1)]

Timed out. \[ \int \frac {1}{\left (a+b \sec ^2(c+d x)\right )^4} \, dx=\text {Timed out} \]

input
integrate(1/(a+b*sec(d*x+c)**2)**4,x)
 
output
Timed out
 
3.3.19.7 Maxima [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 401 vs. \(2 (188) = 376\).

Time = 0.29 (sec) , antiderivative size = 401, normalized size of antiderivative = 1.97 \[ \int \frac {1}{\left (a+b \sec ^2(c+d x)\right )^4} \, dx=-\frac {\frac {3 \, {\left (35 \, a^{3} b + 70 \, a^{2} b^{2} + 56 \, a b^{3} + 16 \, b^{4}\right )} \arctan \left (\frac {b \tan \left (d x + c\right )}{\sqrt {{\left (a + b\right )} b}}\right )}{{\left (a^{7} + 3 \, a^{6} b + 3 \, a^{5} b^{2} + a^{4} b^{3}\right )} \sqrt {{\left (a + b\right )} b}} + \frac {3 \, {\left (19 \, a^{2} b^{3} + 22 \, a b^{4} + 8 \, b^{5}\right )} \tan \left (d x + c\right )^{5} + 8 \, {\left (17 \, a^{3} b^{2} + 35 \, a^{2} b^{3} + 24 \, a b^{4} + 6 \, b^{5}\right )} \tan \left (d x + c\right )^{3} + 3 \, {\left (29 \, a^{4} b + 84 \, a^{3} b^{2} + 89 \, a^{2} b^{3} + 42 \, a b^{4} + 8 \, b^{5}\right )} \tan \left (d x + c\right )}{a^{9} + 6 \, a^{8} b + 15 \, a^{7} b^{2} + 20 \, a^{6} b^{3} + 15 \, a^{5} b^{4} + 6 \, a^{4} b^{5} + a^{3} b^{6} + {\left (a^{6} b^{3} + 3 \, a^{5} b^{4} + 3 \, a^{4} b^{5} + a^{3} b^{6}\right )} \tan \left (d x + c\right )^{6} + 3 \, {\left (a^{7} b^{2} + 4 \, a^{6} b^{3} + 6 \, a^{5} b^{4} + 4 \, a^{4} b^{5} + a^{3} b^{6}\right )} \tan \left (d x + c\right )^{4} + 3 \, {\left (a^{8} b + 5 \, a^{7} b^{2} + 10 \, a^{6} b^{3} + 10 \, a^{5} b^{4} + 5 \, a^{4} b^{5} + a^{3} b^{6}\right )} \tan \left (d x + c\right )^{2}} - \frac {48 \, {\left (d x + c\right )}}{a^{4}}}{48 \, d} \]

input
integrate(1/(a+b*sec(d*x+c)^2)^4,x, algorithm="maxima")
 
output
-1/48*(3*(35*a^3*b + 70*a^2*b^2 + 56*a*b^3 + 16*b^4)*arctan(b*tan(d*x + c) 
/sqrt((a + b)*b))/((a^7 + 3*a^6*b + 3*a^5*b^2 + a^4*b^3)*sqrt((a + b)*b)) 
+ (3*(19*a^2*b^3 + 22*a*b^4 + 8*b^5)*tan(d*x + c)^5 + 8*(17*a^3*b^2 + 35*a 
^2*b^3 + 24*a*b^4 + 6*b^5)*tan(d*x + c)^3 + 3*(29*a^4*b + 84*a^3*b^2 + 89* 
a^2*b^3 + 42*a*b^4 + 8*b^5)*tan(d*x + c))/(a^9 + 6*a^8*b + 15*a^7*b^2 + 20 
*a^6*b^3 + 15*a^5*b^4 + 6*a^4*b^5 + a^3*b^6 + (a^6*b^3 + 3*a^5*b^4 + 3*a^4 
*b^5 + a^3*b^6)*tan(d*x + c)^6 + 3*(a^7*b^2 + 4*a^6*b^3 + 6*a^5*b^4 + 4*a^ 
4*b^5 + a^3*b^6)*tan(d*x + c)^4 + 3*(a^8*b + 5*a^7*b^2 + 10*a^6*b^3 + 10*a 
^5*b^4 + 5*a^4*b^5 + a^3*b^6)*tan(d*x + c)^2) - 48*(d*x + c)/a^4)/d
 
3.3.19.8 Giac [A] (verification not implemented)

Time = 0.32 (sec) , antiderivative size = 324, normalized size of antiderivative = 1.59 \[ \int \frac {1}{\left (a+b \sec ^2(c+d x)\right )^4} \, dx=-\frac {\frac {3 \, {\left (35 \, a^{3} b + 70 \, a^{2} b^{2} + 56 \, a b^{3} + 16 \, b^{4}\right )} {\left (\pi \left \lfloor \frac {d x + c}{\pi } + \frac {1}{2} \right \rfloor \mathrm {sgn}\left (b\right ) + \arctan \left (\frac {b \tan \left (d x + c\right )}{\sqrt {a b + b^{2}}}\right )\right )}}{{\left (a^{7} + 3 \, a^{6} b + 3 \, a^{5} b^{2} + a^{4} b^{3}\right )} \sqrt {a b + b^{2}}} + \frac {57 \, a^{2} b^{3} \tan \left (d x + c\right )^{5} + 66 \, a b^{4} \tan \left (d x + c\right )^{5} + 24 \, b^{5} \tan \left (d x + c\right )^{5} + 136 \, a^{3} b^{2} \tan \left (d x + c\right )^{3} + 280 \, a^{2} b^{3} \tan \left (d x + c\right )^{3} + 192 \, a b^{4} \tan \left (d x + c\right )^{3} + 48 \, b^{5} \tan \left (d x + c\right )^{3} + 87 \, a^{4} b \tan \left (d x + c\right ) + 252 \, a^{3} b^{2} \tan \left (d x + c\right ) + 267 \, a^{2} b^{3} \tan \left (d x + c\right ) + 126 \, a b^{4} \tan \left (d x + c\right ) + 24 \, b^{5} \tan \left (d x + c\right )}{{\left (a^{6} + 3 \, a^{5} b + 3 \, a^{4} b^{2} + a^{3} b^{3}\right )} {\left (b \tan \left (d x + c\right )^{2} + a + b\right )}^{3}} - \frac {48 \, {\left (d x + c\right )}}{a^{4}}}{48 \, d} \]

input
integrate(1/(a+b*sec(d*x+c)^2)^4,x, algorithm="giac")
 
output
-1/48*(3*(35*a^3*b + 70*a^2*b^2 + 56*a*b^3 + 16*b^4)*(pi*floor((d*x + c)/p 
i + 1/2)*sgn(b) + arctan(b*tan(d*x + c)/sqrt(a*b + b^2)))/((a^7 + 3*a^6*b 
+ 3*a^5*b^2 + a^4*b^3)*sqrt(a*b + b^2)) + (57*a^2*b^3*tan(d*x + c)^5 + 66* 
a*b^4*tan(d*x + c)^5 + 24*b^5*tan(d*x + c)^5 + 136*a^3*b^2*tan(d*x + c)^3 
+ 280*a^2*b^3*tan(d*x + c)^3 + 192*a*b^4*tan(d*x + c)^3 + 48*b^5*tan(d*x + 
 c)^3 + 87*a^4*b*tan(d*x + c) + 252*a^3*b^2*tan(d*x + c) + 267*a^2*b^3*tan 
(d*x + c) + 126*a*b^4*tan(d*x + c) + 24*b^5*tan(d*x + c))/((a^6 + 3*a^5*b 
+ 3*a^4*b^2 + a^3*b^3)*(b*tan(d*x + c)^2 + a + b)^3) - 48*(d*x + c)/a^4)/d
 
3.3.19.9 Mupad [B] (verification not implemented)

Time = 25.03 (sec) , antiderivative size = 4506, normalized size of antiderivative = 22.09 \[ \int \frac {1}{\left (a+b \sec ^2(c+d x)\right )^4} \, dx=\text {Too large to display} \]

input
int(1/(a + b/cos(c + d*x)^2)^4,x)
 
output
atan((((((2*a^8*b^8 + (25*a^9*b^7)/2 + (131*a^10*b^6)/4 + (189*a^11*b^5)/4 
 + (161*a^12*b^4)/4 + (77*a^13*b^3)/4 + 4*a^14*b^2)*1i)/(2*(6*a^14*b + a^1 
5 + a^9*b^6 + 6*a^10*b^5 + 15*a^11*b^4 + 20*a^12*b^3 + 15*a^13*b^2)) - (ta 
n(c + d*x)*(2048*a^8*b^9 + 13312*a^9*b^8 + 36864*a^10*b^7 + 56320*a^11*b^6 
 + 51200*a^12*b^5 + 27648*a^13*b^4 + 8192*a^14*b^3 + 1024*a^15*b^2))/(512* 
a^4*(6*a^11*b + a^12 + a^6*b^6 + 6*a^7*b^5 + 15*a^8*b^4 + 20*a^9*b^3 + 15* 
a^10*b^2)))/(2*a^4) + (tan(c + d*x)*(3328*a*b^8 + 512*b^9 + 9216*a^2*b^7 + 
 14080*a^3*b^6 + 12660*a^4*b^5 + 6436*a^5*b^4 + 1481*a^6*b^3))/(256*(6*a^1 
1*b + a^12 + a^6*b^6 + 6*a^7*b^5 + 15*a^8*b^4 + 20*a^9*b^3 + 15*a^10*b^2)) 
)/a^4 - ((((2*a^8*b^8 + (25*a^9*b^7)/2 + (131*a^10*b^6)/4 + (189*a^11*b^5) 
/4 + (161*a^12*b^4)/4 + (77*a^13*b^3)/4 + 4*a^14*b^2)*1i)/(2*(6*a^14*b + a 
^15 + a^9*b^6 + 6*a^10*b^5 + 15*a^11*b^4 + 20*a^12*b^3 + 15*a^13*b^2)) + ( 
tan(c + d*x)*(2048*a^8*b^9 + 13312*a^9*b^8 + 36864*a^10*b^7 + 56320*a^11*b 
^6 + 51200*a^12*b^5 + 27648*a^13*b^4 + 8192*a^14*b^3 + 1024*a^15*b^2))/(51 
2*a^4*(6*a^11*b + a^12 + a^6*b^6 + 6*a^7*b^5 + 15*a^8*b^4 + 20*a^9*b^3 + 1 
5*a^10*b^2)))/(2*a^4) - (tan(c + d*x)*(3328*a*b^8 + 512*b^9 + 9216*a^2*b^7 
 + 14080*a^3*b^6 + 12660*a^4*b^5 + 6436*a^5*b^4 + 1481*a^6*b^3))/(256*(6*a 
^11*b + a^12 + a^6*b^6 + 6*a^7*b^5 + 15*a^8*b^4 + 20*a^9*b^3 + 15*a^10*b^2 
)))/a^4)/((((((2*a^8*b^8 + (25*a^9*b^7)/2 + (131*a^10*b^6)/4 + (189*a^11*b 
^5)/4 + (161*a^12*b^4)/4 + (77*a^13*b^3)/4 + 4*a^14*b^2)*1i)/(2*(6*a^14...